package com.stedu.mall.common.service;

import com.github.pagehelper.PageInfo;
import com.stedu.mall.common.bean.Order;
import com.stedu.mall.common.bean.OrderVo;
import com.stedu.mall.common.exception.SteduException;

public interface OrderService {
    //添加订单
    void insert(OrderVo orderVo) throws SteduException;
    //删除订单
    boolean delete(String id);
    //修改
    boolean update(Order order);
    //通过id查询
    Order selectById(String id);

    Order selectById1(String id, Integer userId) throws SteduException;
    //通过userId查询
    PageInfo<Order> selectByUserId(Integer userId, Integer pageNum, Integer pageSize);

    //查询所有
    PageInfo<Order> selectAll(Order condition, Integer pageNum, Integer pageSize);

    void pay(OrderVo orderVo) throws SteduException;
}
